package com.zizy.healthexpert.Public;

import android.content.Context;

import com.zizy.healthexpert.Database.MyDataBase_T_NUTRITION;

/**
 * Created by Zizy on 2014/5/12.
 */
public class FoodNutrition {
    public static String NutritionID2Name(Context context, int id){
        MyDataBase_T_NUTRITION dataBase_t_foods_nutrition=new MyDataBase_T_NUTRITION(context);
        return dataBase_t_foods_nutrition.SearchT_NUTRITION("*",String.format("_ID = %d",id)).get(0).NAME;


    }
    public static String NutritionID2Unit(Context context, int id){
        MyDataBase_T_NUTRITION dataBase_t_foods_nutrition=new MyDataBase_T_NUTRITION(context);
        return dataBase_t_foods_nutrition.SearchT_NUTRITION("*",String.format("_ID = %d",id)).get(0).UNIT;

    }
}
